package com.heima.feign.clients;

import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.PostMapping;

@FeignClient(value = "leadnews-behavior",path = "/api/v1")
public interface BehaviorClient {
    /**
     * 数据回显——收藏
     */
    @PostMapping("/collection/{userId}/{articleId}")
    public Boolean isCollection(@PathVariable("userId") int userId, @PathVariable("articleId") Long articleId);

    /**
     * 数据回显——点赞
     */
    @PostMapping("/like/{userId}/{articleId}")
    public Boolean isLike(@PathVariable("userId") int userId,
                          @PathVariable("articleId") Long articleId);
}
